const COS = require('cos-nodejs-sdk-v5')
import Config from '@/config/Config'
let cos
export default function getCosInstance() {
  if (!cos) {
    cos = new COS({
      SecretId: Config.COS_CONFIG.SecretId,
      SecretKey: Config.COS_CONFIG.SecretKey,
    })
  }
  return cos
}
